/*  (c) 2008 Benjamin Schroeter
 *  This file is part of JaDAL - Just another DSL-Tools Addon Library
 *  and licensed under the New BSD License
 *  For more information please visit http://www.codeplex.com/JaDAL */
using System;

namespace BenjaminSchroeter.Dsl.UserRestrictions
{
    /// <summary>
    /// This attribute decorates a ModelElement mit special restrictions for 
    /// properties.
    /// When using this attribute the interface ISupportsUserRestrictions
    /// must be implemented.
    /// </summary>
    /// <remarks>
    /// For each property you can add on of these attributes.
    /// </remarks>
    [AttributeUsage(AttributeTargets.Class, AllowMultiple=true)]
    public class CustomRestrictedPropertyAttribute : Attribute
    {
        /// <summary>
        /// Gets or sets the name of the property.
        /// </summary>
        /// <value>The name of the property.</value>
        public string PropertyName{ get; set;}

        /// <summary>
        /// Initializes a new instance of the <see cref="CustomRestrictedPropertyAttribute"/> attribute.
        /// </summary>
        /// <param name="propertyName">Name of the property.</param>
        public CustomRestrictedPropertyAttribute(string propertyName)
        {
            this.PropertyName = propertyName;
        }
    }
}